package edu.whu.demo.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import edu.whu.demo.domain.Commodity;
import com.baomidou.mybatisplus.extension.service.IService;
import edu.whu.demo.domain.Supplier;
import edu.whu.demo.exception.ProductAdminException;
import org.jetbrains.annotations.NotNull;

import java.util.Map;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author yang hengyi
 * @since 2022-10-24
 */
public interface ICommodityService extends IService<Commodity> {

Page<Commodity> findCommodity(@NotNull Map<String, Object> conditions, @NotNull Page page);

Commodity addCommodity(@NotNull Commodity commodity) throws ProductAdminException;

Commodity updateCommodity(@NotNull Commodity commodity) throws ProductAdminException;

void deleteCommodity(long id);

}
